const {getOrders3,deleteOrders,updataOrderS,setOrderDataS,setuserData } = require('../dao/orderDao.js');

// 第二层

// 渲染
module.exports.getOrderData = async () =>{
    const data= await getOrders3()
    // console.log(21)
    return data
}
//删除
module.exports.deleteOrderData = async (orderId) =>{
    const data= await deleteOrders(orderId)
    // console.log(21)
    return data
}
//修改
module.exports.updataOrderF = async (orderId) =>{
    const data= await updataOrderS(orderId)
   
    // console.log(21)
    return data
}
//确认修改
module.exports.setOrderData=async (newOrder)=>{
    console.log(newOrder.userId)
    const usedata= await setuserData(newOrder.userId)
    const data=await setOrderDataS(newOrder)
    return data
}